<?php
	header("Cache-Control: no-cache, must-revalidate");
	header('Content-Type: text/xml; charset=ISO-8859-1');
	echo '<?xml version="1.0" encoding="ISO-8859-1"?>';
	echo '<catalogue>';
	$cnx=mysql_connect('127.0.0.1','root','');
	mysql_select_db('ajax',$cnx);
	$req=mysql_query('select * from produit where pr_categorie='.$_POST['categ']);
	$pdt=mysql_fetch_assoc($req);
	while($pdt)
	{
		echo '<produit>';
		echo '<ref>'.$pdt['pr_id'].'</ref>';
		echo '<des>'.$pdt['pr_libelle'].'</des>';
		echo '</produit>';
		$pdt=mysql_fetch_assoc($req);
	}
	mysql_close($cnx);
	echo '</catalogue>';
?>